FROM adoptopenjdk/openjdk11

#创建的时候将打包好的jar复制进来
ARG JAR_FILE=pianist-1.0.0-SNAPSHOT.jar
COPY ${JAR_FILE} app.jar

COPY application.properties /app/
COPY startup.sh /app/
#COPY arthas/arthas-boot.jar /home/

RUN echo "Asia/Shanghai" > /etc/timezone
RUN mkdir --parents /logs/
RUN chmod +x /app/startup.sh

ENV spring.profiles.active=prod
ENV spring.config.additional-location=/app/

ENTRYPOINT ["/app/startup.sh"]